package com.stedu.bean;

import com.stedu.group.UpdateGroup;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.Valid;
import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 游戏人物表
 * @TableName Characters
 */
@NoArgsConstructor
@Data
@AllArgsConstructor
public class Characters {
    /**
     * 主键
     */
    @NotNull(message = "id不为空",groups = UpdateGroup.class)
    private Long cid;
    /**
     * 游戏人物姓名
     */
    @NotBlank(message = "姓名不为空")
    private String cname;
    /**
     * 赛季是否能选取 1可选取 2不可选取
     */
    @Min(value = 1,message = "最小值为1")
    @Max(value = 2,message = "最大值为2")
    private Integer cban;
    /**
     * 游戏人物所属游戏id
     */
    @NotNull(message = "游戏id不为空")
    private Integer gid;
    /**
     * 游戏信息
     */
    @Valid

    private Games games;
}
